My coding life
On the ST I started "coding" using Omicron Basic which was distributed with the computer. This was lame and quickly I move to GFA Basic with which I did little stuff such as playing a chiptune (a call to an asm routine inside the chiptune!), scrolls, "rasters", line ballets, basic graphical stuff.
On the Amiga, I have used several languages to take inside the code. First I have used Amos, which was a pure pleasure and a powerful Basic. I did some effects using it: infinite bobs (bob = blitter objet, something like a sprite but bigger and managed by a memory blitter inside the Agnus chip if I remember well; the effect consists of putting a bob on a screen, then putting another bob on another screen and swapping the screen, etc. U finally get a lot of 2D stuff on screen moving smoothly and that was beautiful and did not take a lot of CPU cycles...), dual playfield scrollings, 2D starfield dots scrollers, equaliser, fades and copper bars. But soon I understood, this was not good when in-depth control was wanted. I also used RSI DemoMaker, which was a toy. But all these high-levels tools were not ideal for me: of course creation was easier but it was so much that this wasn't programming, this was knob throwing, text entering and such. I was fond of computers and was really interested in understanding the inner working and inner language of the computer. Computer was a bit magic, U know. And controlling the hardware using machine code was something I call an intimacy relationship. Not a physical relationship but an intellectually intensive relationship. This was virtually talking with a CPU using mnemonics, or opcodes. What an experience: This was time consuming like hell, but brain intensive and so interesting: finding what wasn't working, why, finding the solution, optimizing to get some cycles win,... I wasn't efficient but this was instructive: logic was something good as a brain exercice.
Sadly it had a bad side: it put myself into another world I can call "intellectual reality". This is a reality which is based not on facts and money, but on the quest for truth, the quest for the routines taking the least CPU cycles, the quest for understanding the mathematics underlying the effects. And the logical consequence: I was bad at school as using a computer took me all my spare time and even the time to do homework and learning lessons!!! It also has a bad side when social relationships are involved: when U have binary logic, U have a really improved sensitivity and U become a "lunatic" as U live in Ur own world: Ur mental world. Well at least this was true for me, others have been in groups and have hopefully got a normal social life. The fact is, normal people aren't mathematically talking intelligent, so making demos and other intellectually intensive tasks improve Ur brain abilities and make U different from the average brain. And so U became a rebel because U see everything here and there not as good as it could be.
While coding in ASM, I was also interested in cracking and I used intensively "resource", a tool that permits getting ASM code from an exe. This was a disassembler. As I wasn't good at cracking programs, I managed myself to improve others. I then took MasterDir by Pirate and cleaned the code. The result was interesting at least for me as the original tool was a simple dir command and I was a tools compilation maker. So as the Amiga wasn't shipped with a harddrive, I got the idea to make MasterDir resident: on the Amiga with OS till 2.0 there was no dir command in ROM so U had to swap disks to make a dir of another disk or use resident commands. I got "resource", dissassembled the 1KB tool and cleaned everything: I learnt this way how the AmigaOS DOS part was working and also how to write DOS commands. I also learnt how to make programs pure and resident: using dynamic allocation for variables so each instance had its own set of variables. This was interesting but long: in ASM, working with system structures was really a long job as this was all the time using relative addressing to a pointer. Understanding all the needed includes and system functions was also a time consuming task. Using the ASMOne debugger was also a time consuming task but interesting as then I understood what the CPU did with my code and how it played with its registers and condition code register CCR.
With my new ASM skills I decided to train games instead of cracking them: cracking involved a high level when it came to disk drive hardware at least on the Amiga 500, and as I had an Action Replay Cartridge, I had the opportunity to patch games code directly from RAM. Let me present this piece of hardware: a cartridge able to interrupt all programs, exactly like a good debugger of our days like softice, with tons of features like saving a program in its current state to disk, slowmotion, trainer, modules and graphics ripper, disassembler, hex editor, and more. The trainer part was very interesting: it consisted mainly of a memory comparison test which retained all the memory addresses that contained a specific value. First I interrupt the game, then I start the training session with let's say 3 as I get 3 lives in the game, then I go back to the game, I then lose a live, enter the cartrige, I inquire it that now the life counter is equal to 2, then it displays all the memory addresses which were at start equal to 3 and are now equal to 2, then as there were a lot, I re-enter the game, lose a new life, and re-enter the cartrige, ... At the end, I get a few address, let's say 2. This way I use the built-in training command which write protect the address memory and so avoids the life counter to decrease.
But this wasn't funny as I did nothing in ASM with this method. Moreover, sometimes there were not only a few address given by the comparison test but a lot. This case was explained in the manual but the explanation was too simplified: the coder fixed the life counter. So how to train these games? I decided to use the watchpoint command as it was for developer purposes and permitted to invoke the cartidge when a memory address content changed: this is a watchpoint not a breakpoint. When I used this command I found an interesting fact: the PC (Program counter = register which contained the address of the currently executed instruction) pointed exactly to the instruction just before the one which had changed the value of the watched address. So I could understand what this instruction did (usually counters are either increased or decreased by one with an add or a sub) and then change it with one which doesn't change the value. Nowadays cracking is similar to this: U get a program, find its serial number comparison test (a cmp test) and change it to jump all the time to the "U got the good SN, now U have registered version". I have said nothing and I don't encourage U to crack anything. But sometimes this was harder! And this was funny as it involved myself to enter the disassembled code and understand what was done and then change some bits here and there (usually putting nop) to get what I wanted: infinite lives, ammo, time,...
Well training was funny but once understood, it became mechanical, this was no more than boring. So I decided to code in ASM and get some results. My aim was to build the perfect skeleton for ASM coders. A skeleton which was able to run all hardware oriented demo code on every Amiga model from every monitor resolution, from an icon, from Workbench, from CLI, with caches on or off,... This was a hard job and the "How to code" series have helped me a lot like RamJam AGA docs and other interesting 680x0 code docs like my book "Mise en oeuvre du 68000" by Sybex, which had been written by a girl!!! I needed 6 months to get it to run all codes from 68000 to 68040 Motorola Amigas but the 68060 was my killer: this processor was simply too different and needed a complete rewrite I wouldn't make. I didn't have money to buy the 68060 accelerator card and decided to move to the PC as all Amiga extensions involve the same philosophy: a new, improved processor with FPU and MMU = the same philosophy as Intel, MHz race less. As PC was mandatory for my future work life, I decided to move and this wasn't an easy decision to take: the PC was so hated on the Amiga scene and there were so much complaints, this was really a bad moment to go.
On the PC, I got "results" quickly: the OS (DOS) wasn't no more a time trap and in fact when an OS is lame and simple, even too simple, then it's easier to create. This way only one week after getting my first PC, I made a tiny assembly program with TASM : a small (40 bytes) tool which allowed myself to change the path I was in using the content of a file as argument: works like cd <"file with path inside" on Unix. I was really happy: one week of work, and one working program of my own!
Assembly on the PC was a nightmare: not enough flexibility when registers are used, not enough registers, and tons of rules to learn and master before making anything interesting. Docs were once more a big shit: I bought the PC bible 4th edition by MicroApplication, a big book of 1500 pages with everything except what was interesting to read. But I came from the 68000 and I surely lost the Intel philosophy (but as M$ owns 80% of Intel, I believe Intel wasn't anything else than a big firm with money in mind with strategy like optimizing some instructions on their new chip while slowing down older most used ones to make old programs totally useless on the new chip and then pushing people to buy new software with their new hardware). So I decided to use C and ASM really optimised routines to boost the code. On the PC, I haven't realized that everything was easier to code as no optimisation was needed: I have used the same spirit as I had on the Amiga (Optimize everything to the max). This was a big mistake but at least it taught me something: how to interface C code with assembly. And it taught me also one another thing: don't follow the others, be yourself, after all what counts is the result, not to follow the others' rules. I also learned something else with computer studies: make something readable, structured and serviceable. And I finally learned that changing opcodes to faster ones is a real bad habit to lose quickly: what speeds up the code by 5 or by 10 isn't opcodes, it's spirit and especially good and fast algorithms.
Maths haven't been my favourite and 3D wasn't something I got to release anything with. And with the Doom like clones and evolution, I totally stopped trying to make demos: mathematics + war simulation (like doom, quake, ... are) usually cause fear and anxiety inside me. Video games were no more my favourite toys for a simple reason: I was becoming a man and more mature. Morever, I was interested more in the quest for truth (meaning of life, where we come from, where we go, what we are,...) than anything else. I found my way quickly with not so popular a solution: by studies, by reading philosophy, encyclopedia, astrophysicis, maths, religion books and sport. But that's another story.
I decided a last time to make something in the "demo field" or at least the graphical field and I decided to implement the Bresenham algorithm which I got from a VLA tutorial. And once more, few hours after the beginning I was on. In C it was easy, and as I had already written a dot plotting ASM routine I used it so.
I realize this way that what counts is to follow literally what the tutorial or book writer has explained. In fact I understand at his moment that even the human language (at least in the west) is mechanical with laws like grammar and syntax rules to follow and to understand.
I also understand that if something is unclear when reading, then it's because its meaning isn't understood by either my fault or the writer's fault. If it's my fault then this is due to a word definition I don't know, which keeps myself not understanding a sentence or a grammar problem. So I often take my dictionary to get exact definitions of words when I need them.
If it's the writer's fault then he made a grammar mistake or overlooked some information. In this case, I can just skip this information and hope he will talk a bit more about what he explained to fill the gap. If not, then I can forget to use what he said because it's incomplete and I can get other information to fill the gaps.
I have understood too that human language isn't a definite language and often people can understand something when something else was wanted: the meaning of the written words isn't the meaning understood by the reader.
I have understood too that in fact everything in the west has been modeled by spirits and Rene Descartes spirit. I talk about him because I know his philosophy and have seen his method applied here and there (of course his method was also known by other nations and is in fact even known by animals), of course several other great men have improved philosophy in a way or another.
This was the time I understood a lot of things and especially one interesting thing: "everything" is mathematics. Lots of sentences extracted from demos led me to think that. For example I hardly remember sentences extracted from a Complex ECS Intro called WormHole: "I know what I know. You don't know what I know, because if you know what I know, you will be of another nature". The exact sentence are here, I've copied them from screen by viewing the emulated demo on my PC: "You cannot see what I see. You cannot know what I know. because you know what you know. What I see and what I know cannot be added to what you see and what you know because they are not of the same kind. Neither can it replace what you see and what you know because that would be to replace yourself." Wormhole by COMPLEX, code by Owli. These sentences have been in my mind for years and I finally understand that the coder has understood a lot of things about life by the mathematic way following Pythagoras' philosophy which postulated that liberation came with knowledge. I think this coder would mean he was made of spirit whereas others (those who don't know) were made of ignorance. And now I'm sure that by coding, this guy has got a philosophy different from the common man, meaning he has got a philosophy of life which has led him to see things different from how others perceive reality. I will discuss that in another article in hugi 31. This will be what the philosophy in demos bring to your life once understood.
At this time, in 1997, I started to do sports intensively as being all the time sitting and alone led me to be like an old guy who doesn't do anything: out of practice, stuck and quite motionless. I also was disturbed by the fact I lived only on my head and was too much cut from others. Sport helped me to be more sociable and finally allowed me to go beyond my fear of others and allow me to talk with others and also be more active.
I can say that at this moment, the "coder" died as being all the time alone in front of my computer really annoyed myself.
So as a conclusion, code has brought me a structured spirit, a method to do things algorithmically, the way to divide problems into several ones easier to solve. Code spirit was integrated as a part of my whole life's practical philosophy.